Use ValueError instead of RuntimeError when resolving SparkSubmitHook connection#56631
Merged
ephraimbuddy merged 1 commit intoapache:mainfrom Oct 14, 2025
Merged
Conversation
… connection In the future, connection error would raise RuntimeError instead of AirflowException and in that case, if we also have the RuntimeError in the Spark connection, we won't be able to raise it as we would like to catch the RuntimeError from connection. Also, looking at what the code does, ValueError is more appropriate
eladkal
approved these changes
Oct 14, 2025
abdulrahman305 bot
pushed a commit
to abdulrahman305/airflow
that referenced
this pull request
Oct 15, 2025
… connection (apache#56631) In the future, connection error would raise RuntimeError instead of AirflowException and in that case, if we also have the RuntimeError in the Spark connection, we won't be able to raise it as we would like to catch the RuntimeError from connection. Also, looking at what the code does, ValueError is more appropriate
abdulrahman305 bot
pushed a commit
to abdulrahman305/airflow
that referenced
this pull request
Oct 17, 2025
… connection (apache#56631) In the future, connection error would raise RuntimeError instead of AirflowException and in that case, if we also have the RuntimeError in the Spark connection, we won't be able to raise it as we would like to catch the RuntimeError from connection. Also, looking at what the code does, ValueError is more appropriate
abdulrahman305 bot
pushed a commit
to abdulrahman305/airflow
that referenced
this pull request
Oct 19, 2025
… connection (apache#56631) In the future, connection error would raise RuntimeError instead of AirflowException and in that case, if we also have the RuntimeError in the Spark connection, we won't be able to raise it as we would like to catch the RuntimeError from connection. Also, looking at what the code does, ValueError is more appropriate
69 tasks
TyrellHaywood
pushed a commit
to TyrellHaywood/airflow
that referenced
this pull request
Oct 22, 2025
… connection (apache#56631) In the future, connection error would raise RuntimeError instead of AirflowException and in that case, if we also have the RuntimeError in the Spark connection, we won't be able to raise it as we would like to catch the RuntimeError from connection. Also, looking at what the code does, ValueError is more appropriate
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
In the future, connection error would raise RuntimeError instead of AirflowException
and in that case, if we also have the RuntimeError in the Spark connection,
we won't be able to raise it as we would like to catch the RuntimeError from connection.
Also, looking at what the code does, ValueError is more appropriate